<?php
	// sheader('content-type:text/html;charset=utf-8');
	echo "<pre>";
	require_once 'singletonPDO.php';
	$pdo = singletonPDO::getPdo();
	// $pdo -> exec('set names utf8');

	// $sql = "insert into user values('','xiaoming','666')";  //插入
	// $sql = "delete from user where userName = 'xiaoming';	//删除
	// $sql = "update user set userName='frank',password='333' where userName='franky'";	//更新

	// if($pdo->exec($sql)){
	// 	echo '操作成功';	
	// }else{
	// 	echo '操作失败';
	// }

	//pdo查询sql语句
	$sql = "select * from user where 1";
	$result = $pdo->exec($sql);

	var_dump($pdo);

?>